package cn.kgc.easybuy.service;

import cn.kgc.easybuy.pojo.Product;
import com.github.pagehelper.PageInfo;

import java.util.List;
import java.util.Map;

public interface ProductService {
    boolean delProduct(int id);

    boolean updateProduct(Product product);

    boolean addProduct(Product product);

    Product selectProductById(int id);

    List<Product> selectProductAll();

    PageInfo<Product> selectProductByPageWithEs(Map<String,Object> params);

    void saveAllProductToEs();

    boolean sellProduct(Product product);

    boolean refundProduct(Product product);
}
